package phoenix.web.test_objects.data_providers;

import phoenix.core.PhoenixManager;
import phoenix.core.base.extensions.TestBaseExt;
import phoenix.core.data_models.UserProfileDataModel;
import phoenix.core.data_models.UserProfileDataModel.AboutMe;
import phoenix.core.data_models.UserProfileDataModel.LookingFor;
import phoenix.core.data_models.UserProfileDataModel.ProfileDetails;

public class MyProfileDataProviders extends TestBaseExt
{
	public MyProfileDataProviders(PhoenixManager p_phoenix)
	{
		super(p_phoenix);
	}

	public Object[][] myProfileData()
	{
		UserProfileDataModel dataModel = new UserProfileDataModel(manager);

		ProfileDetails details = dataModel.new ProfileDetails();
		details.fillUpMyProfile(testUser().getGender());
		LookingFor lookingFunnel = dataModel.new LookingFor(testUser().getGender(), testUser().getPostcode());
		lookingFunnel.fillUpForFunnel(testUser().getGender(), manager.testUser().getPostcode());

		LookingFor lookingMyProfile = dataModel.new LookingFor(testUser().getGender(), testUser().getPostcode());
		lookingMyProfile.fillUpForMyProfile(testUser().getGender());
		AboutMe about = dataModel.new AboutMe();
		about.fillUpAboutMe();

		return new Object[][]
		{
				{ details, lookingFunnel, about, lookingMyProfile }
		};
	}

	public Object[][] myProfileOldData()
	{
		UserProfileDataModel dataModel = new UserProfileDataModel(manager);

		ProfileDetails details = dataModel.new ProfileDetails();
		details.fillUpMyProfileDate("12", "11", "1990");

		String p_lookingGender = (manager.testUser().getGender().equals("male")) ? "female" : "male";
		LookingFor fixtureForOLD = dataModel.new LookingFor(testUser().getGender(), testUser().getPostcode());
		fixtureForOLD.fillLookingFor("35", "60", manager.testUser().getPostcode(), "20", "test status", "test description", p_lookingGender);

		LookingFor lookingMyProfile = dataModel.new LookingFor(testUser().getGender(), testUser().getPostcode());
		lookingMyProfile.fillUpForMyProfile(testUser().getGender());
		AboutMe about = dataModel.new AboutMe();
		about.fillUpAboutMe();

		return new Object[][]
		{
				{ details, fixtureForOLD, about, lookingMyProfile }
		};
	}
}